<template>
  <!-- <v-app class="dashboardAppIndex"> </v-app> -->
  <div>
    Dashboard
  </div>
</template>

<script>
import { IsPC } from '@/utils/judgePC'

export default {
  name: 'Dashborad',

  components: {},

  data() {
    return {}
  },

  watch: {
    screenWidth(screenNewWidth) {
      this.isPC = IsPC()
      if (this.isPC) {
        this.cusomBtnStyle = {}
        this.copyrightStyle = {}
        if (screenNewWidth > 1400 && screenNewWidth < 1700) {
          this.setCopyrightStyle()
        } else if (screenNewWidth > 900 && screenNewWidth < 1400) {
          this.cusomBtnStyle = {
            bottom: '10%',
            width: '100%',
            position: 'absolute'
          }
          this.setCopyrightStyle()
        } else {
          this.cusomBtnStyle.position = ''
          this.cusomBtnStyle.width = ''
        }
        // console.log('screenWidth: ', this.screenWidth, '| screenHeight：', this.screenHeight, '| isPC：', this.isPC)
      }
    },
    isPC(nv) {
      if (nv) {
        this.setCopyrightStyle()
      } else {
        this.copyrightStyle = {}
      }
    }
  },
  created() {},

  mounted() {
    this.screenWidth = document.body.clientWidth
    this.screenHeight = document.body.clientHeight
    window.onresize = () => {
      return (() => {
        this.screenWidth = document.body.clientWidth
        this.screenHeight = document.body.clientHeight
      })()
    }
    this.isPC = IsPC()
  },

  methods: {
    setCopyrightStyle() {
      this.copyrightStyle = {
        position: 'absolute',
        width: '100%',
        bottom: 0
      }
    }
  }
}
</script>

<style lang="scss" scoped></style>
